3.345 \(\int \frac{x^m (A+B x)}{a+b x} \, dx\)

Optimal. Leaf size=56 \[ \frac{x^{m+1} (A b-a B) \, _2F_1\left (1,m+1;m+2;-\frac{b x}{a}\right )}{a b (m+1)}+\frac{B x^{m+1}}{b (m+1)} \]

[Out]

(B*x^(1 + m))/(b*(1 + m)) + ((A*b - a*B)*x^(1 + m)*Hypergeometric2F1[1, 1 + m, 2
 + m, -((b*x)/a)])/(a*b*(1 + m))

_______________________________________________________________________________________

Rubi [A]  time = 0.0748232, antiderivative size = 56, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 16, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.125 \[ \frac{x^{m+1} (A b-a B) \, _2F_1\left (1,m+1;m+2;-\frac{b x}{a}\right )}{a b (m+1)}+\frac{B x^{m+1}}{b (m+1)} \]

Antiderivative was successfully verified.

[In]  Int[(x^m*(A + B*x))/(a + b*x),x]

[Out]

(B*x^(1 + m))/(b*(1 + m)) + ((A*b - a*B)*x^(1 + m)*Hypergeometric2F1[1, 1 + m, 2
 + m, -((b*x)/a)])/(a*b*(1 + m))

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 7.43386, size = 41, normalized size = 0.73 \[ \frac{B x^{m + 1}}{b \left (m + 1\right )} + \frac{x^{m + 1} \left (A b - B a\right ){{}_{2}F_{1}\left (\begin{matrix} 1, m + 1 \\ m + 2 \end{matrix}\middle |{- \frac{b x}{a}} \right )}}{a b \left (m + 1\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(x**m*(B*x+A)/(b*x+a),x)

[Out]

B*x**(m + 1)/(b*(m + 1)) + x**(m + 1)*(A*b - B*a)*hyper((1, m + 1), (m + 2,), -b
*x/a)/(a*b*(m + 1))

_______________________________________________________________________________________

Mathematica [A]  time = 0.0579569, size = 45, normalized size = 0.8 \[ \frac{x^{m+1} \left ((A b-a B) \, _2F_1\left (1,m+1;m+2;-\frac{b x}{a}\right )+a B\right )}{a b (m+1)} \]

Antiderivative was successfully verified.

[In]  Integrate[(x^m*(A + B*x))/(a + b*x),x]

[Out]

(x^(1 + m)*(a*B + (A*b - a*B)*Hypergeometric2F1[1, 1 + m, 2 + m, -((b*x)/a)]))/(
a*b*(1 + m))

_______________________________________________________________________________________

Maple [F]  time = 0.061, size = 0, normalized size = 0. \[ \int{\frac{{x}^{m} \left ( Bx+A \right ) }{bx+a}}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int(x^m*(B*x+A)/(b*x+a),x)

[Out]

int(x^m*(B*x+A)/(b*x+a),x)

_______________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{{\left (B x + A\right )} x^{m}}{b x + a}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((B*x + A)*x^m/(b*x + a),x, algorithm="maxima")

[Out]

integrate((B*x + A)*x^m/(b*x + a), x)

_______________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \[{\rm integral}\left (\frac{{\left (B x + A\right )} x^{m}}{b x + a}, x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((B*x + A)*x^m/(b*x + a),x, algorithm="fricas")

[Out]

integral((B*x + A)*x^m/(b*x + a), x)

_______________________________________________________________________________________

Sympy [A]  time = 6.21045, size = 136, normalized size = 2.43 \[ \frac{A m x x^{m} \Phi \left (\frac{b x e^{i \pi }}{a}, 1, m + 1\right ) \Gamma \left (m + 1\right )}{a \Gamma \left (m + 2\right )} + \frac{A x x^{m} \Phi \left (\frac{b x e^{i \pi }}{a}, 1, m + 1\right ) \Gamma \left (m + 1\right )}{a \Gamma \left (m + 2\right )} + \frac{B m x^{2} x^{m} \Phi \left (\frac{b x e^{i \pi }}{a}, 1, m + 2\right ) \Gamma \left (m + 2\right )}{a \Gamma \left (m + 3\right )} + \frac{2 B x^{2} x^{m} \Phi \left (\frac{b x e^{i \pi }}{a}, 1, m + 2\right ) \Gamma \left (m + 2\right )}{a \Gamma \left (m + 3\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x**m*(B*x+A)/(b*x+a),x)

[Out]

A*m*x*x**m*lerchphi(b*x*exp_polar(I*pi)/a, 1, m + 1)*gamma(m + 1)/(a*gamma(m + 2
)) + A*x*x**m*lerchphi(b*x*exp_polar(I*pi)/a, 1, m + 1)*gamma(m + 1)/(a*gamma(m
+ 2)) + B*m*x**2*x**m*lerchphi(b*x*exp_polar(I*pi)/a, 1, m + 2)*gamma(m + 2)/(a*
gamma(m + 3)) + 2*B*x**2*x**m*lerchphi(b*x*exp_polar(I*pi)/a, 1, m + 2)*gamma(m
+ 2)/(a*gamma(m + 3))

_______________________________________________________________________________________

GIAC/XCAS [F]  time = 0., size = 0, normalized size = 0. \[ \int \frac{{\left (B x + A\right )} x^{m}}{b x + a}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((B*x + A)*x^m/(b*x + a),x, algorithm="giac")

[Out]

integrate((B*x + A)*x^m/(b*x + a), x)